﻿<%@ Page Title="" Language="C#" MasterPageFile="~/module/Fontend.Master" AutoEventWireup="true" CodeBehind="TeacherKidList.aspx.cs" Inherits="mamnontuoitho7.module.TeacherKidList" %>
<%@ Import Namespace="mamnontuoitho7.AppCode" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder2" runat="server">

<div class="accounts">
    <div class="login-name">
        <div class="login-name-left"></div>
        <span class="login-name-middle"><%= Session["fullname"].ToString()%></span>
        <div class="login-name-right"></div>
    </div>
    
    <div class="block-menu">
        <ul>
            <li><a href="TeacherConversation.aspx">Các cuộc hội thoại</a></li>
            <li class="active">Danh sách Bé</li>
            <li><a href="TeacherWarning.aspx">Thông báo</a></li>
            <li><a href="TeacherProfile.aspx">Thông tin tài khoản</a></li>
            <li><a href="ChangeAvatar.aspx">Thay đổi Avatar</a></li>
        </ul>
    </div>
    <div class="block-content">
<%
/* Check class has kid or not */
    if (_dttKid.Rows.Count > 0)
    {
        for (int i = 0; i < _dttKid.Rows.Count; i++)
        {
            if (i % 2 == 0)
            {%>
            <div class="kidlist-left">
                <a href="KidDetails.aspx?KidID=<%= _dttKid.Rows[i]["KidID"].ToString()%>">
                    <img src="../images/avatar/kid/<%= _dttKid.Rows[i]["KidAvatar"].ToString() != "" ?  _dttKid.Rows[i]["KidAvatar"].ToString() : ConstantClass._kidDefaultAvatar %>?<%=DateTime.Now.Ticks %>" alt="" class="img80x80"/>
                    <span class="buttonstxt">
                        <%= _dttKid.Rows[i]["KidLastName"].ToString() + " " + _dttKid.Rows[i]["KidFirstName"].ToString()%>
                    </span>
                </a>
            </div>
        <%}
            else
            { %>
            <div class="kidlist-right">
                <a href="KidDetails.aspx?KidID=<%= _dttKid.Rows[i]["KidID"].ToString()%>">
                    <img src="../images/avatar/kid/<%= _dttKid.Rows[i]["KidAvatar"].ToString() != "" ?  _dttKid.Rows[i]["KidAvatar"].ToString() : ConstantClass._kidDefaultAvatar %>?<%=DateTime.Now.Ticks %>" alt="" class="img80x80"/>
                    <span class="buttonstxt">
                        <%= _dttKid.Rows[i]["KidLastName"].ToString() + " " + _dttKid.Rows[i]["KidFirstName"].ToString()%>
                    </span>
                </a>
            </div>
     <%     }
        }
    }
    else
    {
        %>
        <p class="commingsoon">Hiện chưa có học sinh nào trong lớp.</p>
  <%} %>
    </div>
</div>
</asp:Content>
